home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c-part1 / 1624 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  1.9 KB

  1. Path: news.infi.net!usenet
  2. From: nngis@norfolk.infi.net (Greg DiGiorgio)
  3. Newsgroups: comp.lang.c
  4. Subject: Re: An incredably dumb question
  5. Date: 14 Jan 1996 23:59:30 GMT
  6. Organization: Customer of InfiNet
  7. Message-ID: <4dc5d2$13m@news.infi.net>
  8. References: <4d8tlk$pgk@ccnet3.ccnet.com>
  9. NNTP-Posting-Host: h-langoliers.norfolk.infi.net
  10. Mime-Version: 1.0
  11. X-Newsreader: WinVN 0.99.3
  12.  
  13. In article <4d8tlk$pgk@ccnet3.ccnet.com>, felinoid@ccnet.com says...
  14. >
  15. >        and I should be able to figure it out myself....
  16. >But I can't.....
  17.  
  18. *** So? That's what everyone is here for. You give it a shot and then 
  19. *** ask.
  20.  
  21. >
  22. >        I am learninf C (Already got the FAQ) also make use of old 3b2
  23.  
  24. *** Good thing that you got the FAQ, anyway.
  25.  
  26. >programming manuals and "Teach yourself C"
  27. >        But with all that I STILL can't figure this out...
  28. >
  29. >        Here is my question....
  30. >I am looking for an alternitive to getc()   I want to read carciters
  31. >as they are entered NOT after the user hits return.
  32. >I feal so stupid that I can't find it myself or figure it out...
  33.  
  34. *** You're teaching yourself 'C' and come up against something you can
  35. *** not figure out without help? That doesn't make you stupid. In fact,
  36. *** if 1/2 of the people I work with would ask others how to resolve 
  37. *** problems, we would not have as many problems to contend with.
  38.  
  39. >Must be right under my nose... or I'd have it by now...
  40.  
  41. *** Well, if it was a snake, it would still be hidden. So... what you 
  42. *** want to do is platform specific. That is, you want to read each
  43. *** character as it is typed, not after the user presses <ENTER>.
  44. *** With Turbo or Borland C/C++, the function you want is "getch". It
  45. *** is prototyped in "conio.h" which is where all OS-specific console i/o
  46. *** functions go. If you're not using Borland, I don't know what MS calls 
  47. *** it. If you're not programming MS-DOS, then I can't help either.
  48.  
  49.  
  50. >Jeff
  51. >--
  52. >felinoid@ccnet.com
  53. >http://www.ccnet.com/~felinoid/
  54.  
  55.